package br.edu.ufersa.scrumgame.facade;

import java.util.List;

import javax.ejb.EJB;
import javax.ejb.Stateless;

import br.edu.ufersa.scrumgame.dao.PapelDAO;
import br.edu.ufersa.scrumgame.modelo.Papel;

@Stateless
public class PapelFacadeImp implements PapelFacade {
	
	@EJB
	private PapelDAO papelDAO;
	
	@Override
	public void save(Papel papel) {
		papelDAO.save(papel);
	}

	@Override
	public Papel update(Papel papel) {
		return papelDAO.update(papel);
	}

	@Override
	public void delete(Papel papel) {
		papelDAO.delete(papel);
		
	}

	@Override
	public Papel find(int entityID) {
		return papelDAO.find(entityID);
	}
	
	@Override
	public List<Papel> findAll() {
		return papelDAO.findAll();
	}

	@Override
	public Papel findByDescricao(String descricao) {
		return papelDAO.findByDescricao(descricao);
	}

	
}
